package app.texas.com.devilfishhouse.Base;


/**
 * Created by lenovo on 2018/5/21.
 */
interface Presenter {
    void oncreate();

    void onResume();

    void onDestory();

    void performOnClick();
}

public class BasePresenter<T> implements Presenter {
    protected static BaseIView iView;
    protected BaseModel iModel;
    protected T obj;
    protected static BasePresenter mPersenter;

    public BasePresenter(BaseIView iView) {
        this.iView = iView;
    }

    public static synchronized BasePresenter getInstancePre(BaseIView iView) {
        mPersenter = new BasePresenter(iView);
        return mPersenter;
    }

    @Override
    public void oncreate() {
        iModel = getIModel();
    }

    public BaseModel getIModel() {
        return null;
    }

    @Override
    public void onResume() {

    }

    @Override
    public void onDestory() {

    }

    //入口1
    @Override
    public void performOnClick() {

    }
}
